package main

import "fmt"

// 写一个程序，把字符串转化为布尔类型：
// “true”, “yes”, “1” 是 true
// “false”, “no”, “0” 是 false
// 针对其它值，显示错误信息

func main() {
	yesNo := "1"

	var launch bool

	switch yesNo {
	case "true", "yes", "1":
		launch = true
	case "false", "no", "0":
		launch = false
	default:
		fmt.Println(yesNo, "is not valid")
	}

	fmt.Println("Ready for launch:", launch)
}
